<!-- INCLUDE sv_overall_header.html -->


<!-- IF  S_USE_HTML5_CANVAS -->	
<script src="{T_TEMPLATE_PATH}/RGraph/RGraph.common.core.js" ></script>
<script src="{T_TEMPLATE_PATH}/RGraph/RGraph.common.dynamic.js" ></script>
<script src="{T_TEMPLATE_PATH}/RGraph/RGraph.tooltips.js" ></script>
<script src="{T_TEMPLATE_PATH}/RGraph/RGraph.line.js" ></script>
<!-- ENDIF -->


<!-- IF IN_FB_IFRAME -->
	<script type="text/javascript" src="../ofc/js/json/json2.js"></script>
	<script type="text/javascript" src="../ofc/js/swfobject.js"></script>
	<script type="text/javascript">
	swfobject.embedSWF("../ofc/open-flash-chart.swf", "my_chart", "680", "350", "9.0.0");
	</script>
<!-- ELSE -->
	<script type="text/javascript" src="ofc/js/json/json2.js"></script>
	<script type="text/javascript" src="ofc/js/swfobject.js"></script>
	<script type="text/javascript">
	swfobject.embedSWF("ofc/open-flash-chart.swf", "my_chart", "950", "550", "9.0.0");
	</script>
<!-- ENDIF -->

<script type="text/javascript">

function ofc_ready()
{
    //alert('ofc_ready');
}

function open_flash_chart_data()
{
    //alert( 'reading data' );
    return JSON.stringify(data);
}

function findSWF(movieName) {
  if (navigator.appName.indexOf("Microsoft")!= -1) {
    return window[movieName];
  } else {
    return document[movieName];
  }
}
    
var data = {JASON_STRING};

</script>

<script type="text/javascript" language="JavaScript">
	    function ShowContent(d) 
	    {
			document.getElementById(d).style.display = "block";
		}
		function HideContent(d) 
	    {
			document.getElementById(d).style.display = "none";
		}
		function ShowShareOption()
		{
			ShowContent('share_div');			
			document.getElementById('share_url').focus();
		}			
</script>





<!-- IF not S_USER_LOGGED_IN and not S_IS_BOT -->
	<form method="post" action="{S_LOGIN_ACTION}" class="headerspace">
	<h3><a href="{U_LOGIN_LOGOUT}">{L_LOGIN_LOGOUT}</a><!-- IF S_REGISTER_ENABLED -->&nbsp; &bull; &nbsp;<a href="{U_REGISTER}">{L_REGISTER}</a><!-- ENDIF --></h3>
		<fieldset class="quick-login">
			<label for="username">{L_USERNAME}:</label>&nbsp;<input type="text" name="username" id="username" size="10" class="inputbox" title="{L_USERNAME}" />
			<label for="password">{L_PASSWORD}:</label>&nbsp;<input type="password" name="password" id="password" size="10" class="inputbox" title="{L_PASSWORD}" />
			<!-- IF S_AUTOLOGIN_ENABLED -->
				| <label for="autologin">{L_LOG_ME_IN} <input type="checkbox" name="autologin" id="autologin" /></label>
			<!-- ENDIF -->
			<input type="submit" name="login" value="{L_LOGIN}" class="button2" />
			{S_LOGIN_REDIRECT}
		</fieldset>
	</form>
<!-- ENDIF -->

<div class="panel" > 
	<div class="inner"><span class="corners-top"><span></span></span> 
	<h2>{L_SV_PERFORMANCE}
	
	<a href="javascript:ShowShareOption()">	({L_SV_SHARE}) </a>	
	
	</h2> 
	</div>
	
	
<div id="share_div" style="display:none;">	
	<a href="
		https://www.facebook.com/dialog/feed?
  		app_id={S_FB_APP_ID}&
  		link={BOARD_URL}query_user.php?mode=query_user%26user_id={S_USER_ID}&
  		picture={BOARD_URL}{T_IMAGES_PATH}logo.jpg&
  		name={U_USERNAME} - {SITENAME} &
  		caption={L_SV_ABOUT_CONTENT}&
  		description=
  		<!-- IF SHOW_1_MONTH_ROI -->	
		{U_USERNAME}%20-%20{L_SV_ROI_LAST_1_MONTH}:{S_ROI_1_MONTH}%25%2C%20
		<!-- ENDIF -->	
		
		<!-- IF SHOW_3_MONTH_ROI -->
		{L_SV_ROI_LAST_3_MONTH}:{S_ROI_3_MONTH}	%25%2C%20
		<!-- ENDIF -->	
		
		<!-- IF SHOW_6_MONTH_ROI -->	
		{L_SV_ROI_LAST_6_MONTH}:{S_ROI_6_MONTH}%25%2C%20
		<!-- ENDIF -->	
		
		<!-- IF SHOW_12_MONTH_ROI -->
		{L_SV_ROI_LAST_12_MONTH}:{S_ROI_12_MONTH}%25%2C%20
		<!-- ENDIF -->			
  		
  		&
  		redirect_uri={BOARD_URL}fb/redirect.php?mode=self_close
  		" 
  		target="_blank">
  	{L_SV_SHARE_ON_FB}
	</a>
 <BR>
 <BR>
	<label for="username">{L_SV_SHARE_URL}  </label>&nbsp;
	<input type="text" name="share_url" id="share_url" size="10" class="inputbox" title="{L_SV_SHARE_URL_TIP}" 
			value="{BOARD_URL}query_user.php?mode=query_user&user_id={S_USER_ID}"
	/>
	<BR>
	<BR>
</div>
<!-- IF S_PERFORMANCE  -->

	<span style="float:right">	
	<a  href="{BOARD_URL}download.php?mode=user_value&user_id={S_USER_ID}"  >
				<img title="{L_SV_USER_VALUE_DOWNLOAD_TIP}" src="{T_IMAGES_PATH}csv_file.png"  width="36" height="36" class='edit_note_icon'/> 
			</a>			
	</span>	
	
	
	<!-- IF S_SHOW_BELIEF -->
	<table border="0" cellpadding="5" cellspacing="5">
		<tr>
			<td><p>{L_SV_INVESTMENT_BELIEF}</p></td> 
			<td><p>{S_BELIEF}</p></td>
		</tr>	
	</table>
	<!-- ENDIF -->	
	
	
	<!-- INCLUDE user_roi.html -->
	
<!-- IF ! S_USE_HTML5_CANVAS -->

<div id="my_chart"></div>

<!-- ELSE -->

<canvas id="user_value_canvas" width="700" height="460"> </canvas>   </td>

<script>
            
var line = new RGraph.Line('user_value_canvas', [{S_USER_VALUE_HTML5}]);
		//line.set('tooltips', ['{S_USER_VALUE_TOOLTIP_HTML5}']);
		line.set('tooltips', ['1','2']);
        line.set('spline', true);
        line.set('numxticks', 11);
        line.set('numyticks', 5);
        line.set('axis.color', 'blue');
        
        line.set('background.grid.autofit.numvlines', 11);
        line.set('colors', ['blue']);
        line.set('linewidth', 2);
        line.set('gutter.left', 70);
        line.set('gutter.right', 70);
        //line.set('labels',['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec']);
        line.set('shadow',true);
        line.set('shadow.color','#aaa');
        line.set('shadow.blur',5);
        line.set('tickmarks',null);
        line.draw();
        
var line2 = new RGraph.Line('user_value_canvas', [9000000, 9000000 ]);
		//line.set('tooltips', ['{S_USER_VALUE_TOOLTIP_HTML5}']);
		line2.set('tooltips', ['1','2']);
        line2.set('spline', true);
        line2.set('numxticks', 11);
        line2.set('numyticks', 5);
        line2.set('axis.color', 'blue');
        
        line2.set('background.grid.autofit.numvlines', 11);
        line2.set('colors', ['blue']);
        line2.set('linewidth', 2);
        line2.set('gutter.left', 70);
        line2.set('gutter.right', 70);
        //line.set('labels',['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec']);
        line2.set('shadow',true);
        line2.set('shadow.color','#aaa');
        line2.set('shadow.blur',5);
        line2.set('tickmarks',null);
        line2.draw();
        
        
var taiex_line = new RGraph.Line('user_value_canvas', [{S_TAIEX_HTML5}]);
        taiex_line.set('spline', true);
        taiex_line.set('numxticks', 11);
        
        taiex_line.set('yaxispos', 'right');
        taiex_line.set('numyticks', 5);
        taiex_line.set('background.grid.autofit.numvlines', 11);
        taiex_line.set('colors', ['grey']);
        taiex_line.set('linewidth', 1);
        taiex_line.set('gutter.left', 70);
        taiex_line.set('gutter.right', 70);
        //taiex_line.set('labels',['Jan','Feb','Mar','Apr','May','Jun','Jul','Aug','Sep','Oct','Nov','Dec']);
        taiex_line.set('shadow',true);
        taiex_line.set('shadow.color','#aaa');
        taiex_line.set('shadow.blur',5);
        taiex_line.set('tickmarks',null);
        taiex_line.draw();
        
</script>

<!-- ENDIF -->

<!-- IF S_SHOW_BRIEF_HISTORY -->
		<!-- INCLUDE brief_history.html -->
	<!-- ENDIF -->	
	
<!-- ELSE -->
{L_SV_NO_PERFORMANCE}
<!-- ENDIF -->
</div>


<!-- INCLUDE delegation_list.html -->


<div class="panel" > 
	<div class="inner"><span class="corners-top"><span></span></span> 
	<h2>{L_SV_EQUITY_CHANGE_LOG}</h2> 
	</div>
	<!-- IF S_EQUITY_CHANGE_LIST  -->
	<table border="0" cellpadding="5" cellspacing="5">
		<tr>			
			<td><p>{L_SV_SCHEDULED_DATE}</p></td>
			<td><p>{L_SV_EXECUTION_DATE}</p></td>			
			<td><p>{L_SV_CORP_NAME}</p></td>
			<td><p>{L_SV_SHARE_BEFORE_CHANGE}</p></td>
			<td><p>{L_SV_DISPATCHED_CASH}</p></td>
			<td><p>{L_SV_SHARE_AFTER_CHANGE}</p></td>
			
		</tr>
		<!-- BEGIN equity_change_log_list -->
		<tr>
			<td><p>{equity_change_log_list.SCHEDULED_DATE}</p></td>
			<td><p>{equity_change_log_list.EXECUTION_DATE}</p></td>			
			<td><p>{equity_change_log_list.CORP_NAME}({equity_change_log_list.CORP_ID})</p></td>
			<td><p>{equity_change_log_list.SHARE}</p></td>
			<td><p>{equity_change_log_list.USER_GET_CASH_AFTER_CHANGE}</p></td>
			<td><p>
				<!-- IF equity_change_log_list.CORP_ID == equity_change_log_list.USER_GET_CORP_ID_AFTER_CHANGE  -->
				{equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE}
				<!-- ELSE -->
				{equity_change_log_list.CORP_NAME_AFTER_CHANGE}({equity_change_log_list.USER_GET_CORP_ID_AFTER_CHANGE}) {equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE} {L_SV_SHARE}
				<!-- ENDIF -->
				<!-- IF equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE_2 != 0  -->
				, {L_SV_DISPATCH_IN_ADDITION} {equity_change_log_list.CORP_NAME_AFTER_CHANGE_2}({equity_change_log_list.USER_GET_CORP_ID_AFTER_CHANGE_2}) {equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE_2} {L_SV_SHARE}
				<!-- ENDIF -->
				<!-- IF equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE_3 != 0  -->
				,  {equity_change_log_list.CORP_NAME_AFTER_CHANGE_3}({equity_change_log_list.USER_GET_CORP_ID_AFTER_CHANGE_3}) {equity_change_log_list.USER_GET_SHARE_AFTER_CHANGE_3} {L_SV_SHARE}
				<!-- ENDIF -->
			</p></td>
			
		</tr>
		<!-- END equity_change_log_list -->
	</table>
	<!-- ELSE -->
	{L_SV_NO_HISTORY}
	<!-- ENDIF -->
</div>



<!-- INCLUDE sv_overall_footer.html -->